package cn.devices.service;

import cn.devices.dto.SelectBorrowDto;
import cn.devices.dto.UserBorrowDto;
import cn.devices.entity.TbBorrow;
import com.github.pagehelper.PageInfo;

import java.util.List;

/**
 * <p>
 * 设备出借表 服务类
 * </p>
 *
 * @author 秋水浮萍
 * @since 2021-02-07
 */
public interface TbBorrowService {
    String borrow(String deviceCode);
    int userCount(String userId);
    int count(String deviceCode);
    UserBorrowDto userBorrowDtoDm(String userId, String deviceCode);

    UserBorrowDto userBorrowDtoSelf(String userId, String deviceCode);

    TbBorrow tbBorrowSelect( String deviceCode);

    PageInfo<SelectBorrowDto> BorrowDtoList(int pageIndex, int pageSize,String beginTime,String endTime,String userName,String telephone
            ,String deviceCode,String deviceName,String typeId);

    int tbBorrowAdd(TbBorrow tbBorrow);
    String img(String userId);

    int isBorrow(String isBorrow, String deviceCode,String deviceStatus);

    int tbBorrowUpdate(TbBorrow tbBorrow);

    List<TbBorrow> getUserIdBorrow(String userId);

}
